import request from '@/utils/request'

// 查询会员卡列表
export function listCards(query) {
  return request({
    url: '/hatha/cards/list',
    method: 'get',
    params: query
  })
}

// 查询会员卡详细
export function getCards(id) {
  return request({
    url: '/hatha/cards/' + id,
    method: 'get'
  })
}

// 新增会员卡
export function addCards(data) {
  return request({
    url: '/hatha/cards',
    method: 'post',
    data: data
  })
}

// 修改会员卡
export function updateCards(data) {
  return request({
    url: '/hatha/cards',
    method: 'put',
    data: data
  })
}

// 删除会员卡
export function delCards(id) {
  return request({
    url: '/hatha/cards/' + id,
    method: 'delete'
  })
}
